<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="f"  uri="http://java.sun.com/jsf/core"%>
<%@ taglib prefix="h"  uri="http://java.sun.com/jsf/html"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<f:view>
	<h:form id="form">
    <h:panelGrid id="panel" columns="3" border="1" cellpadding="0" cellspacing="2">
        <f:facet name="header">
            <h:outputText id="loginLabel" value="#{msg['login']}"/>
        </f:facet>
        <h:outputLabel id="username" value="#{msg['UserName']}" />
        <h:inputText id="usernametxt" value="#{loginBean.userName}" required="true"  ></h:inputText>
        <h:message for="usernametxt" showSummary="true" style="color: red"></h:message>
        
        <h:outputLabel id="password" value="#{msg['Password']}" />
        <h:inputSecret id="passwordtxt" value="#{loginBean.password}" required="true" ></h:inputSecret>
       
        <h:message for="passwordtxt" showSummary="true" style="color: red"></h:message>
        
        <f:facet name="footer">
            <h:panelGroup style="display:block; text-align:center">
                <h:commandButton id="submit" value="#{msg['submit']}" action="IniciarSesion"  />
            </h:panelGroup>
        </f:facet>
        <h:panelGrid columns="2">
 		<h:outputText id="lenguaje" value="#{msg['lenguage']}"></h:outputText>
		<h:selectOneMenu value="#{language.localeCode}" onchange="submit()"
			valueChangeListener="#{language.countryLocaleCodeChanged}">
   			<f:selectItems value="#{language.countriesInMap}" /> 
   		</h:selectOneMenu>
 
	</h:panelGrid>
    </h:panelGrid>
</h:form>
</f:view>
</body>
</html>